<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <script type="text/javascript">
        var iNum01 = 2;
        var sNum01 = '2';
        // ==  
        /*  
               if(iNum01 == sNum01){
                    alert('相等');
                }
                else{
                    alert('不相等');
                } 
        */
        if (iNum01 === sNum01) {
            alert('相等');
        } else {
            alert('不相等');
        }

    </script>
    <title>Document</title>
</head>

<body>


</body>

</html>